package com.itheima.dubbo.mysql.impl;


import com.alibaba.dubbo.config.annotation.Service;
import com.baomidou.mybatisplus.core.toolkit.Wrappers;
import com.itheima.commons.model.domain.Questionnaire;
import com.itheima.dubbo.interfaces.QuestionnaireApi;
import com.itheima.dubbo.mysql.mapper.QuestionnaireMapper;
import org.springframework.beans.factory.annotation.Autowired;

import java.util.List;


@Service
public class QuestionnaireApiImpl implements QuestionnaireApi {

    @Autowired
    private QuestionnaireMapper questionnaireMapper;

    @Override
    public List<Questionnaire> findAll() {
        return  questionnaireMapper.selectList(Wrappers.lambdaQuery(Questionnaire.class));
    }
}
